<%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%@ include file="/WEB-INF/jsp/include/taglibs.jsp"%>
<%--@elvariable id="actionBean" type="com.goodedeeds.webapp.controller.BaseDashboardAction"--%>

<c:if test="${actionBean.currentTab != null}">
    <div class="content">
        <div class="dashboard-tabs">
            <ul class="dashboard-tabs-group">
                <c:forEach items="${actionBean.tabs}" var="tab" varStatus="status">
                    <c:choose>
                        <c:when test="${actionBean.currentTab == tab}">
                            <li class="dashboard-tab dashboard-tab-selected">${tab.displayName}</li>
                        </c:when>
                        <c:otherwise>
                            <li class="dashboard-tab">
                                <stripes:link href="${tab.action}" class="mainLinks" id="${status.index}">${tab.displayName}</stripes:link>
                            </li>
                        </c:otherwise>
                    </c:choose>
                </c:forEach>
            </ul>
        </div>
        <div class="clear"></div>
    </div>
</c:if>
<c:choose>
<c:when test="${actionBean.currentSubTab != null}">
    <div id="sub-tab-parent">
        <div class="sub-tabs">
            <c:if test="${!empty actionBean.subTabs}">
                <c:forEach items="${actionBean.subTabs}" var="subTab">
                    <c:choose>
                        <c:when test="${subTab == actionBean.currentSubTab}">
                            <span class="sub-tab-link sub-tab-current">${subTab.displayName}</span>
                        </c:when>
                        <c:otherwise>
                            <stripes:link class="sub-tab-link" href="${subTab.action}">${subTab.displayName}</stripes:link>
                        </c:otherwise>
                    </c:choose>
                </c:forEach>
            </c:if>
        </div>
    </div>
</c:when>
    <c:otherwise><div class="clear"></div></c:otherwise>
    </c:choose>
<div class="dashboard-content">
    <c:if test="${!empty actionBean.dashboardContent}">
        <jsp:include page="${actionBean.dashboardContent}" />
    </c:if>
</div>